﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Threading.Tasks;

namespace Electronic_work_order.Model
{
    public class Demand
    {
        //人员需求
        [Key]
        public int DemandID { get; set; }  //需求编号
        public DateTime Stime { get; set; } //申请日期
        public DateTime Rtime { get; set; } //入职日期
       
        public string DeName { get; set; }//   --申请人
        public int OrganizationID { get; set; }

        [ForeignKey("OrganizationID")]
        public virtual Organization Organization { get; set; } //部门编号  --部门名称

        public int PositionID { get; set; } //职位

       // [ForeignKey("PositionID")]
        //public virtual Position Position { get; set; } //职位

        public int num { get; set; }  //职位空缺数
        public string cause { get; set; }  //申请原因
        public string need { get; set; }  //要求

        public int Process_State_ID { get; set; }//外键审核表

        [ForeignKey("Process_State_ID")]
        public virtual Process_application_State Process_Application_State { get; set; }

        [ForeignKey("Aid")]
        public int Aid { get; set; }//申请类型态表
        public virtual application Application { get; set; }

        public int Manager_id { get; set; }  //审核人

        public string Agency_ID { get; set; }
    }
}
